package com.example.tse.rbhttpservice.service.moments.model;

import java.util.List;
import java.util.ArrayList;
import com.example.tse.rbhttpservice.service.RudderResponse;


//import com.rbyair.services.moments.model.MomentsHomeGetRecommendList;
/**
 * 点击首页的达人推荐进入，显示所有推荐给当前用户达人列表，对于所有用户推荐数据都是相同
 * @author wliu
 * edit tse
 */
public class MomentsHomeGetRecommendListResponse extends RudderResponse{
    
    private List<MomentsHomeGetRecommendList> getRecommendList = new ArrayList<MomentsHomeGetRecommendList>();
		
	
    /**
     * @return getRecommendList
     */	
    public List<MomentsHomeGetRecommendList> getGetRecommendList() { 
	    return this.getRecommendList;
    };
	
	/**
     * @return getRecommendList
     */	
    public void setGetRecommendList(List<MomentsHomeGetRecommendList> getRecommendList) { 
        this.getRecommendList = getRecommendList;
    };
    
	
        
    private static void filterFor(MomentsHomeGetRecommendListMoments moments) {
        if (moments.getMomentId() == null) {
            moments.setMomentId("");
        }
        if (moments.getMainPic() == null) {
            moments.setMainPic("");
        }
    }
        
    private static void filterFor(MomentsHomeGetRecommendList moments) {
        if (moments.getMemberId() == null) {
            moments.setMemberId("");
        }
        if (moments.getNickname() == null) {
            moments.setNickname("");
        }
        if (moments.getAvatar() == null) {
            moments.setAvatar("");
        }
        if (moments.getDesc() == null) {
            moments.setDesc("");
        }
        if (moments.getIsNoticed() == null) {
            moments.setIsNoticed("");
        }
        if (moments.getMoments() == null) {
            moments.setMoments(new ArrayList<MomentsHomeGetRecommendListMoments>());
        } else {
            for (MomentsHomeGetRecommendListMoments item : moments.getMoments()) {
                filterFor(item);
            }
        }
    }
        
    public static void filter(MomentsHomeGetRecommendListResponse moments) {
        if (moments.getGetRecommendList() == null) {
            moments.setGetRecommendList(new ArrayList<MomentsHomeGetRecommendList>());
        } else {
            for (MomentsHomeGetRecommendList item : moments.getGetRecommendList()) {
                filterFor(item);
            }
        }
    }
}
